package sessionbeans;

import entities.HelpRequest;
import java.util.List;
import javax.ejb.Remote;

@Remote
public interface HelpRequestBeanRemote {

	/**
	 * 
	 * @param userId the user whose pending help requests will be retrieved
	 * @return a possibly empty list of all pending help requests received by the user
	 */
	List<HelpRequest> getPendingRequests(String userId);
	
	/**
	 * 
	 * @param requestId the help request's identifier
	 * @param answer the answer to the request (true stays for "yes", false stays for "no")
	 */
	void answerToHelpRequest(String requestId, boolean answer);
	
	/**
	 * 
	 * @param sender the user ID of the sender
	 * @param receiver the user ID of the receiver
	 * @param abilityName the name of the ability on which the sender is asking for help
	 * @param place the place of the possible meeting between the user
	 * @param description general description of the request
	 * @param retribution amount of the proposed pay
	 * @return
	 */
	String sendHelpRequest(String sender, String receiver, String abilityName, String place, String description, double retribution);
}
